home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC Media 22
/
PC MEDIA CD22.iso
/
share
/
prog
/
datalib2
/
exop.hpp
< prev
next >
Wrap
C/C++ Source or Header
|
1995-08-14
|
963b
|
47 lines
/*
This file is the data required for the expression evaluator.
*/
extern struct opinf oppt[];
// Maximum operator length
#define MAXOPLEN 9
// Number of operators
extern int nop;
// Lookup table for end of array and spaces
extern char sparray[];
/* Substitutions for operators */
enum {
OBRAC=0,CBRAC,PLUS,MINUS,POW,TIMES,DIVIDE,AND,OR,NOT,EQUAL,NE,GTE,
LTE,GT,LT,DOLLAR,ABS,ASC,AT,CDOW,CHR,CMONTH,CTOD,
DATE,DAY,DOW,DTOC,DTOS,IIF,INT,ISALPHA,ISDIGIT,
ISLOWER,ISUPPER,LEFT,LEN,LOWER,LTRIM,
MAX,MIN,MOD,MONTH,RECCOUNT,RECNO,RECSIZE,
REPLICATE,RIGHT,ROUND,RTRIM,SOUNDEX,
SPACE,STR,STUFF,SUBSTR,SWAPDATA,TIME,TRIM,
TYPE,UPPER,VAL,YEAR,POW2,NE2
};
/* Type of operators */
enum {CONSTANT=0,UNARY,BINARY,BOTH,FUNCTION};
// Expression tokeniser substitutions
#define EXSTART -1
#define EXINT -2
#define EXVAR -3
#define EXEND -4
#define EXSTR -5